package baseTest;

public class invertTree {
    public static void main(String[] args) {

    }
    public TreeNode process(TreeNode root){
        if (root == null){
            return root;
        }
        TreeNode left = root.left;
        root.left = root.right;
        root.right = left;

        process(root.left);
        process(root.right);
        return root;
    }
}
